//src/stores/user.js
import {defineStore} from 'pinia'

//给当前的缓存取个user名字
export const useUserStore = defineStore('user', {
  state: () => {
    return {
      userInfo: [] 
    }
  },
  getters: {

  },
  actions:{
    async getUserData(data){
      console.log('getUserData in', data);
      this.userInfo.push(...data) 
    }
  }
})